package org.jinyan.utils;

import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.Date;

public class LogSysoutUtils {
	private static DateFormat dateFormatter = new SimpleDateFormat(
			"yyyyMMdd HH:mm:ss");
	
	public static void log(String info){
		System.out.println("SERVER [" + dateFormatter.format(new Date())
				+ "]: "+info);
	}
	
	public static void log(String info,Throwable e){
		System.err.println("SERVER [" + dateFormatter.format(new Date())
				+ "]: "+info+":"+e.getLocalizedMessage());
	}

}
